package com.ngmaster.apiserver.services.impl;

import java.io.IOException;

import org.springframework.stereotype.Service;

import com.ngmaster.apiserver.common.BaseBody;
import com.ngmaster.apiserver.common.LocationBody;
import com.ngmaster.apiserver.services.MessageService;

@Service
public class MessageServiceImpl implements MessageService{
	
	@Override
	public BaseBody getMessage(String message,String messageCmd,String time) throws IOException {
		//message  :89 86 02 b1 03 17 00 11 71 84 02 00 01 01 5F5F
		//messageCmd :02
		//time :20180805150049932
		LocationBody locationBody = new LocationBody();
		try {
			if(message!=null && messageCmd!=null && time!=null ){
				locationBody.setMessage(message+" "+time);
			}
		} catch (Exception e) {
			e.printStackTrace();
		}
		return locationBody;
	}

}
